#!/usr/bin/perl

open FILE, "all_music_themes";

while (<FILE>) {
    chomp;
    /theme\/(.*)/;
    $theme = $1;
    open CUR, "all_music_theme_pages/$theme";
    while (<CUR>) {
    	chomp;
        if (/http:\/\/allmusic\.com\/song\/(.*?)\">/) {
        	system("echo $1 >> all_music_theme_songs/$theme");
        }
    }
}
